Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

default session saving completed & tested #156

Merged
merged 17 commits into from
Jan 19, 2024
Merged

Conversation

gigajuwels
Copy link
Contributor

No description provided.

@gigajuwels gigajuwels requested a review from skibitsky November 12, 2023 18:45
Copy link
Member

@skibitsky skibitsky left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good! Just a few small requests and questions

Core Modules/WalletConnectSharp.Storage/InMemoryStorage.cs Outdated Show resolved Hide resolved
WalletConnectSharp.Core/Controllers/Relayer.cs Outdated Show resolved Hide resolved
WalletConnectSharp.Sign/Models/DefaultsLoadingEventArgs.cs Outdated Show resolved Hide resolved
WalletConnectSharp.Sign/Controllers/AddressProvider.cs Outdated Show resolved Hide resolved
WalletConnectSharp.Sign/Controllers/AddressProvider.cs Outdated Show resolved Hide resolved
@skibitsky
Copy link
Member

There is another issue that can break session requests.

Engine now uses OrderedKeys field when making requests:
https://github.com/WalletConnect/WalletConnectSharp/blob/feat/default-session-saving/WalletConnectSharp.Sign/Engine.cs#L687

The problem I'm sometimes facing is that RequiredNamespace object can have one Key, but no OrderedKeys. Perhaps there is a scenario when dictionary is assigned directly, bypassing the Add method of RequiredNamespaces.

@gigajuwels gigajuwels requested a review from skibitsky November 29, 2023 17:03
@skibitsky
Copy link
Member

@gigajuwels the TestAddressProviderDefaultsSaving test fails

gigajuwels and others added 9 commits December 9, 2023 18:13
`OrderedKeys` has always been 0 when deserializing the Namespaces JSON. The issue was solved by replacing `SortedDictionary` with an implementation from `System.Collections.Generic`.
# Conflicts:
#	Core Modules/WalletConnectSharp.Storage/FileSystemStorage.cs
@skibitsky
Copy link
Member

Well done, @gigajuwels!

@skibitsky skibitsky merged commit ec81740 into 2.0 Jan 19, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants